//
//  UIImage+My.h
//  My00
//
//  Created by 黄杰 on 15/1/21.
//  Copyright (c) 2015年 黄杰. All rights reserved.
//

#import <UIKit/UIKit.h>

@interface UIImage (My)
/**
 *  返回拉伸后的图片
 */
+ (UIImage *)resizeWithImageName:(NSString *)imageName;

/**
 *  返回一张自由拉伸图片
 */
+ (UIImage *)resizeImageWithName:(NSString *)name left:(CGFloat)left top:(CGFloat)top;

/**
 *  返回一张适应iPhone5\iPhone4的全屏图片
 */
+ (UIImage *)fullScreenImageName:(NSString *)name;

+ (UIImage *)resizeableImage:(NSString *)name;

/**
 *  增加高斯模糊
 */
+ (UIImage *)blurryImage:(UIImage *)image withBlurLevel:(CGFloat)level;

/**
 *  增加毛玻璃效果
 */
+ (UIImage *)imageWithOriginalImage:(UIImage *)originImage withCutRect:(CGRect)rect blurLevel:(CGFloat)level;

/**
 *  保持原来的长宽比，生成一个缩略图
 */
+ (UIImage *)thumbnailWithImageWithoutScale:(UIImage *)image size:(CGSize)asize;

/**
 *  根据view生成一张截图
 */
+ (UIImage *)captureWithView:(UIView *)view;

- (UIImage*)scaleToSize:(CGSize)size;

@end
